﻿using Abp.Dependency;
using JetBrains.Annotations;

namespace Mt.Site.Core.Security
{
    public class StringEncryptionService : IStringEncryptionService, ITransientDependency
    {
        public string Decrypt([CanBeNull] string cipherText, string passPhrase = null, byte[] salt = null)
        {
            return SimpleStringCipherHelper.Decrypt(cipherText);
        }

        public string Encrypt([CanBeNull] string plainText, string passPhrase = null, byte[] salt = null)
        {
            return SimpleStringCipherHelper.Encrypt(plainText);
        }
    }
}
